package util;

import android.content.ContentResolver;
import android.content.ContentValues;
import android.content.Context;
import android.net.Uri;

import io.github.mthli.Ninja.Activity.BrowserActivity;
import io.github.mthli.Ninja.Database.Record;
import io.github.mthli.Ninja.Database.RecordAction;

/**
 * Created by lhj on 2018/3/17.
 */

public class BookMarketUtil {
    public static void insertBookMark(Context mContext, int id, String title, String url) {
        RecordAction action = new RecordAction(mContext);
        action.open(true);
        action.addBookmark(new Record(id,title, url, System.currentTimeMillis()));
        action.close();



    }
    public static  void deleteBookMark(Context mContext, int id) {
        RecordAction action = new RecordAction(mContext);
        action.open(true);
        action.deleteBookmark(id);
        action.close();

    }
    public static  void updateBookMark(Context mContext, int id,String url,String title) {
        RecordAction action = new RecordAction(mContext);
        action.open(true);
        action.updateBookmark(id,url,title);
        action.close();

    }
}
